<template>
  <div id="attendance" class="attendance has-header has-menu">
    <it-header :from="false" :showAvatar="false" title="出勤"></it-header>
    <!-- 日历 -->
    <calendar class="border-b-1px" :zero="calendar.zero" :events="calendar.events" :lunar="calendar.lunar" :value="calendar.value" :begin="calendar.begin" :end="calendar.end" @select="calendar.select"></calendar>
    <!-- 日期信息 -->
    <div class="date-info-itle">
      <span style="font-size: 16px;">白班</span>
      <i class="ion ion-ios-time-outline"></i>
      <span>09:00-18:00</span>
    </div>
    <div class="date-info-list">
      <mt-cell title="您忘记打卡了">
        <span class="dispose">处理</span>
        <i slot="icon" class="ion ion-ios-partly-sunny-outline" aria-hidden="true"></i>
      </mt-cell>
      <mt-cell title="您未打卡">
        <i slot="icon" class="ion ion-ios-moon-outline" aria-hidden="true"></i>
      </mt-cell>
    </div>
    <it-menu></it-menu>
  </div>
</template>
<script>
export default {
  name: 'attendance',
  data() {
    return {
      calendar: {
        zero: true,
        value: [2018, 2, 16], //默认日期
        // lunar:true, //显示农历
        // weeks: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
        // months: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],
        events: {
          '2018-2-14': '$408',
          '2018-2-15': '$460',
          '2018-2-16': '$500'
        },
        select(value) {
          console.log(value.toString())
        },
        timestamp: Date.now()
      }
    }
  }
}

</script>
<style>
.attendance {
  height: 100%;
  background-color: #eee;
  overflow: auto;
}
.date-info-itle {
  padding-left: 15px;
  line-height: 0.6rem;
  background-color: #eee;
  font-size: 12px;
}

.dispose {
  min-width: 18px;
  padding: 3px 8px;
  color: #5e7a88;
  font-size: 14px;
  line-height: 18px;
  border-radius: 4px;
  text-align: center;
  border: 1px solid #5e7a88;
}

</style>
